package com.woniu.apartment.domain;

import java.io.Serializable;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 汇率对象 tb_exchange_rate
 *
 * @author yy
 * @date 2023-04-03
 */
@ApiModel(value = "ExchangeRate", description = "汇率")
public class ExchangeRate implements Serializable
{
    private static final long serialVersionUID = 1L;

    /** 汇率表主键 */
    @ApiModelProperty("汇率表主键")
    private Long id;

    /** 源货币 */
    @Excel(name = "源货币")
    @ApiModelProperty("源货币")
    private String sourceCurrency;

    /** 目标货币 */
    @Excel(name = "目标货币")
    @ApiModelProperty("目标货币")
    private String targetCurrency;

    /** 汇率 */
    @Excel(name = "汇率")
    @ApiModelProperty("汇率")
    private Long exchangeRate;

    /** 汇率公布时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "汇率公布时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty("汇率公布时间")
    private Date validDate;

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }
    public void setSourceCurrency(String sourceCurrency)
    {
        this.sourceCurrency = sourceCurrency;
    }

    public String getSourceCurrency()
    {
        return sourceCurrency;
    }
    public void setTargetCurrency(String targetCurrency)
    {
        this.targetCurrency = targetCurrency;
    }

    public String getTargetCurrency()
    {
        return targetCurrency;
    }
    public void setExchangeRate(Long exchangeRate)
    {
        this.exchangeRate = exchangeRate;
    }

    public Long getExchangeRate()
    {
        return exchangeRate;
    }
    public void setValidDate(Date validDate)
    {
        this.validDate = validDate;
    }

    public Date getValidDate()
    {
        return validDate;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("sourceCurrency", getSourceCurrency())
            .append("targetCurrency", getTargetCurrency())
            .append("exchangeRate", getExchangeRate())
            .append("validDate", getValidDate())
            .toString();
    }
}
